package edu.fdzc.learn.service;

import com.baomidou.mybatisplus.extension.service.IService;
import edu.fdzc.learn.entity.ExamSubmission;
import edu.fdzc.learn.entity.UserAnswer;
import edu.fdzc.learn.entity.vo.ExamResultVO;
import edu.fdzc.learn.entity.vo.ExamSubmissionVO;

import java.util.List;

public interface ExamSubmissionService extends IService<ExamSubmission> {
    /**
     * 提交考试答案并返回提交记录ID
     */
    Long submitExam(ExamSubmissionVO submissionVO);

    /**
     * 获取考试结果
     */
    ExamResultVO getExamResult(Long submissionId);

    Integer calculateScore(Long examId, List<UserAnswer> userAnswers);

    /**
     * 计算考试成绩
     *

    /**
     * 根据提交ID查询考试提交信息
     */
    ExamSubmission getSubmissionById(Long submissionId);
}